﻿@{
    ViewBag.Title = "Cập nhật danh mục";
    Layout = "~/Views/Shared/_Layout.Management.cshtml";
}

<form method="post" class="form" action="/Management/CategoryList/Edit/@ViewBag.CategoryId">
	<fieldset id="firstStep">
		<h2 class="app">
	        <strong>Express - Cập nhật danh mục</strong>
        </h2>
		<div class="errorMessage" data-bind="visible: InvalidateForm" >
			<span class="error">Xin hãy nhập thông tin bên dưới chính xác.</span>
		</div>				
		<div class="title">
			<h3>Thông tin danh mục</h3>
		</div>
		<div id="editform" class="columns">
			<div class="col columnedit">
				<div class="row">
					<label>Tên danh mục:</label>
					<input class="text" style="width:500px" type="text" data-bind="value: Name, attr:{maxlength:50}" name="Name" />
                </div>                 
				<div class="row">
					<label>Thứ tự:</label>
					<input class="text" style="width:60px" type="text" data-bind="value: SortOrder, attr:{maxlength:5}" name="SortOrder" />
                </div>
				<div class="row">
					<label>Kích hoạt:</label>
                    <div class="groupinput" id="editform"><input class="text" type="checkbox" data-bind="checked: Active" name="Active" /></div>
					 
				</div>
			</div>
		</div> 

        <!-- button below -->
		<div class="foot-info">
			<h3 class="centered-wbtn centered-wbtn-bottom save">
  				<span>
  					<a class="btn btn-cancel-page" href="/Management/CategoryList">previous</a>
					<input type="button" class="btn btn-submit-page" data-bind="click: SubmitForm" value="Submit" />
                </span>
			</h3>
		</div>
	</fieldset>
</form>
<script type="text/javascript">
    var data = @(Html.Raw(Json.Encode(Model)));
</script>
<script src="/Scripts/ViewModel/editcategory.js" type="text/javascript"></script>